import agentscope
from agentscope.agents import UserAgent
from agentscope.agents.dialog_agent import DialogAgent
from agentscope.message.msg import Msg

model_configs = [
    {
        "model_type": "openai_chat",
        "config_name": "vllm-openai-api",
        "model_name": "Qwen/Qwen2.5-7B-Instruct",
        "client_args": {
            "base_url": "http://10.0.102.69:8000/v1",
        },
        "api_key": "123456",
        "generate_args": {"temperature": 0.2},
        "stream": True,
    },
]
agentscope.init(model_configs=model_configs)

agent = DialogAgent(name="qwen2.5-7b", model_config_name="vllm-openai-api", sys_prompt="You are a helper assistant.")

user = UserAgent(name="User", input_hint="User Input ('exit' to quit): ")

vision_msg = Msg(name="user", content="在Windows上如何查看本机IP", role="user")

response = agent(vision_msg)
print(response.content)
